set title "Data cache misses prediction, soplex"
set xlabel 'nb of samples out of 13583364'
set ylabel 'cache misses ratio, 20 estimations'
set autoscale
set xtics auto
unset logscale
set logscale x
#set yrange [-0.001:0.004]
#set xrange [4:16384]
set xtics (8, "2^4" 16, "2^5" 32, "2^6" 64, "2^7" 128, "2^8" 256, "2^9" 512, "2^{10}" 1024, "2^{11}" 2048, "2^{12}" 4096, "2^{13}" 8192, "2^{14}" 16384, "2^{15}" 32768, "2^{16}" 65536, "2^{17}" 131072, "2^{18}" 262144, "2^{19}" 524288, "2^{20}" 1048576, "2^{21}" 2097152, "2^{22}" 4194304, "2^{23}" 8388608, "2^{24}" 16777216, "2^{25}" 33554432, "2^{26}" 67108864)
unset grid
set grid y
plot  1200818. / 13583364. title '80kB actual' lt 1, \
     "data/isoplex-biased3-2048.dat" using 1:5:7 title '80kB biased 3 iterations' with yerrorbar lt 1 pt 2, \
     "data/isoplex-biased50-2048.dat" using 1:5:7 title '80kB biased 50 iterations' with yerrorbar lt 1 pt 3

# plot 14914. / 19967409. title '16kB actual' lt 2, \
#      "data/isoplex-GPD.dat" using 1:5:7 title '16kB' with yerrorbar lt 2 pt 1, \
#      "data/isoplex-biased3.dat" using 1:5:7 title '16kB biased 3 iterations' with yerrorbar lt 2 pt 2, \
#      "data/isoplex-biased50.dat" using 1:5:7 title '16kB biased 50 iterations' with yerrorbar lt 2 pt 3

# plot  1856. / 19967409. title '32kB actual' lt 3, \
#     "data/isoplex-GPD.dat" using 1:8:10 title '32kB' with yerrorbar lt 3 pt 1, \
#     "data/isoplex-biased3.dat" using 1:8:10 title '32kB biased 3 iterations' with yerrorbar lt 3 pt 2, \
#     "data/isoplex-biased50.dat" using 1:8:10 title '32kB biased 50 iterations' with yerrorbar lt 3 pt 3

#plot 39571. / 19967409. title '8kB actual' lt 1, \
#     "data/isoplex-GPD.dat" using 1:2:4 title '8kB GPD' with yerrorbar lt 1 pt 1, \
#     "data/isoplex-biased3.dat" using 1:2:4 title '8kB biased 3 iterations' with yerrorbar lt 1 pt 2, \
#     "data/isoplex-biased50.dat" using 1:2:4 title '8kB biased 50 iterations' with yerrorbar lt 1 pt 3, \

#     "data/isoplex-trunc.dat" using 1:2:4 title '8kB truncated' with yerrorbar lt 1 pt 4, \
#     "data/isoplex-trunc.dat" using 1:5:7 title '16kB truncated' with yerrorbar lt 2 pt 4, \
#     "data/isoplex-trunc.dat" using 1:8:10 title '32kB truncated' with yerrorbar lt 3 pt 4

#plot "danalysis-ls.dat" using 1:5:7 title '64kB' with yerrorbar lt 2 pt 1, \
#    "danalysista-ls.dat" using 1:5:7 title '64kB trunkated' with yerrorbar lt 2 pt 4, \
#    "danalysist-ls.dat" using 1:5:7 title '64kB biased 3 iterations' with yerrorbar lt 2 pt 2, \
#    "danalysist50-ls.dat" using 1:5:7 title '64kB biased 50 iterations' with yerrorbar lt 2 pt 3, \
#     2511. / 225946. title '64kB actual' lt 2, \
#    "danalysis-ls.dat" using 1:2:4 title '32kB' with yerrorbar lt 1 pt 1, \
#    "danalysista-ls.dat" using 1:2:4 title '32kB trunkated' with yerrorbar lt 1 pt 4, \
#    "danalysist-ls.dat" using 1:2:4 title '32kB biased 3 iterations' with yerrorbar lt 1 pt 2, \
#    "danalysist50-ls.dat" using 1:2:4 title '32kB biased 50 iterations' with yerrorbar lt 1 pt 3, \
#     5043. / 225946. title '32kB actual' lt 1


#plot "danalysis-ls.dat" using 1:5:7 title '64kB' with yerrorbar lt 2 pt 1, \
#     "danalysista-ls.dat" using 1:5:7 title '64kB trunkated' with yerrorbar lt 2 pt 4, \
#     "danalysist-ls.dat" using 1:5:7 title '64kB biased 3 iterations' with yerrorbar lt 2 pt 2, \
#     "danalysist50-ls.dat" using 1:5:7 title '64kB biased 50 iterations' with yerrorbar lt 2 pt 3, \
#      2511. / 225946. title '64kB actual' lt 2, \
#     "danalysis-ls.dat" using 1:2:4 title '32kB' with yerrorbar lt 1 pt 1, \
#     "danalysista-ls.dat" using 1:2:4 title '32kB trunkated' with yerrorbar lt 1 pt 4, \
#     "danalysist-ls.dat" using 1:2:4 title '32kB biased 3 iterations' with yerrorbar lt 1 pt 2, \
#     "danalysist50-ls.dat" using 1:2:4 title '32kB biased 50 iterations' with yerrorbar lt 1 pt 3, \
#      5043. / 225946. title '32kB actual' lt 1


#     "ianalysis-dealII.dat" using 1:2:4 title '32kB cache prediction' with yerrorbar lt 1, \
#     "ianalysis-dealII.dat" using 1:5:7 title '64kB prediction' with yerrorbar lt 2, \
#      103. / (2945444. - 15355.) title '32kB cache actual samples' lt 1, \
#      0. title '64kB actual samples' lt 2

#     "distances.dat" using 1:3 title '32kB cache max' with lines lt 1, \
#      11248. / 883131. title '32kB cache actual whole run' lt 1, \
#      1848. / 383131. title '32kB cache actual sampled portion' lt 1, \

#     "distances.dat" using 1:6 title '64kB prediction' with lines lt 2, \
#      1040. / 883131. title '64kB actual whole run' lt 2, \
#      1040. / 383131. title '64kB actual whole sampled portion' lt 2, \


#     "distances.dat" using 1:8:10 title '128kB prediction' with yerrorbar lt 3, \
#      0. title '128kB actual' lt 3